<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<title>企业账户注册</title>
<link href="css/bootstrap.min.css" rel="stylesheet">
<link href="css/gloab.css" rel="stylesheet">
<link href="css/index.css" rel="stylesheet">
<script src="js/jquery-1.11.1.min.js"></script>
<script src="js/register.js"></script>
</head>
<body class="bgf4">
<div class="login-box f-mt10 f-pb50">
	<div class="main bgf">    
    	<div class="reg-box-pan display-inline">  
        	<div class="step">        	
                <ul>
                    <li class="col-xs-4 on">
                        <span class="num"><em class="f-r5"></em><i>1</i></span>
                        <span class="line_bg lbg-r"></span>
                        <p class="lbg-txt">创建账户</p>
                    </li>
                    <li class="col-xs-4">
                        <span class="num"><em class="f-r5"></em><i>2</i></span>
                        <span class="line_bg lbg-l"></span>
                        <span class="line_bg lbg-r"></span>
                        <p class="lbg-txt">填写账户信息</p>
                    </li>
                    <li class="col-xs-4">
                        <span class="num"><em class="f-r5"></em><i>3</i></span>
                        <span class="line_bg lbg-l"></span>
                        <p class="lbg-txt">企业实名认证</p>
                    </li>
                </ul>
            </div>
        	<div class="reg-box" id="verifyCheck" style="margin-top:20px;">
            	<div class="part1">
                    <form id="regForm">
                        <input type="text" name="userType" value="2" hidden>
                    <div class="item col-xs-12">

                        <span class="intelligent-label f-fl"><b class="ftx04">*</b>账户名：</span>
                        <div class="f-fl item-ifo">
                            <input type="text" id="email" maxlength="20" class="txt03 f-r3 required" tabindex="1" data-valid="isNonEmpty||between:3-20||isEmail" data-error="邮箱不能为空||邮箱长度3-20位||只能输入中文、字母、数字、下划线，且以中文或字母开头"  />                            <span class="ie8 icon-close close hide"></span>
                            <label class="icon-sucessfill blank hide"></label>
                            <label class="focus"><span>请输入可用电子邮箱，此邮箱将与您的账户绑定</span></label>
                            <label class="focus valid"></label>
                        </div>
                    </div>
                    <div class="item col-xs-12">
                        <span class="intelligent-label f-fl"><b class="ftx04">*</b>验证码：</span>    
                        <div class="f-fl item-ifo">
                            <input type="text" maxlength="4" class="txt03 f-r3 f-fl required" tabindex="4" style="width:167px" id="randCode" data-valid="isNonEmpty" data-error="验证码不能为空" /> 
                            <span class="ie8 icon-close close hide"></span>
                            <label class="f-size12 c-999 f-fl f-pl10">
                            	<img src="images/yzm.jpg" />                               
                            </label>                        
                            <label class="icon-sucessfill blank hide" style="left:380px"></label>
                            <label class="focusa">看不清？<a href="javascript:;" class="c-blue">换一张</a></label>   
                            <label class="focus valid" style="left:370px"></label>                        
                        </div>
                    </div>
                    <div class="item col-xs-12" style="height:auto">
                        <span class="intelligent-label f-fl">&nbsp;</span>  
                        <p class="f-size14 required"  data-valid="isChecked" data-error="请先同意条款"> 
                        	<input type="checkbox" checked /><a href="javascript:showoutc();" class="f-ml5">我已阅读并同意条款</a>
                        </p>                       
                        <label class="focus valid"></label> 
                    </div> 
                    <div class="item col-xs-12">
                <span class="intelligent-label f-fl">&nbsp;</span>
                <div class="f-fl item-ifo">
                    <a href="javascript:;" class="btn btn-blue f-r3" id="btn_part1">下一步</a>
                </div>
            </div>
                </form>
            </div>
                <div class="part2" style="display:none">
                    <div  style="width:700px;height: 100px"></div>
                	<div class="alert alert-info" style="width:700px">
                        <h4>下一步注册链接已发送至您的邮箱，
                        <span  id="EmaliNumber"></span><br><br>
                        请在30个工作日内登陆邮箱点击链接，完善企业实名信息。</h4></div>
                    <div class="item col-xs-12">
                        <span class="intelligent-label f-fl">&nbsp;</span>
                    </div>
                    <label class="focus">
                    <h5>开启交易新旅程....</h5>
                    </label>
                </div>
            </div>
        </div>
    </div>
</div>
<div class="m-sPopBg" style="z-index:998;"></div>
<div class="m-sPopCon regcon">
	<div class="m-sPopTitle"><strong>服务协议条款</strong><b id="sPopClose" class="m-sPopClose" onClick="closeClause()">×</b></div>
    <div class="apply_up_content">
    	<pre class="f-r0">
		<strong>同意以下服务条款，提交注册信息</strong>
        </pre>
    </div>
    <center><a class="btn btn-blue btn-lg f-size12 b-b0 b-l0 b-t0 b-r0 f-pl50 f-pr50 f-r3" href="javascript:closeClause();">已阅读并同意此条款</a></center>
</div>
<script>
$(function(){	
	//第一页的确定按钮
	$("#btn_part1").click(function(){
		$(".part1").hide();
        $("#EmaliNumber").html($("#email").val());
        $.ajax({
            url:"http://127.0.0.1:8061/LogAndReg/insertUserLogin",
            type : "post",
            data : $("#regForm").serialize(),
            dataType : "json",
            success : function(aa) {
                if(aa.i==1){
                    $("#userId").val(aa.id);
                    insertIdCard();
                    $(".part4").show();
                }
            },
            error : function() {
                $(".part5").show();
            }
        })
		$(".part2").show();
		$(".step li").eq(1).addClass("on");
	});

});

function showoutc(){$(".m-sPopBg,.m-sPopCon").show();}
function closeClause(){
	$(".m-sPopBg,.m-sPopCon").hide();		
}
</script>
</body>
</html>
